home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Controls / Visual Basic Controls.iso / vbcontrol / polardrw / data.z / frmShadowLens.frm < prev    next >
Text File  |  1999-06-03  |  7KB  |  240 lines

  1. VERSION 5.00
  2. Object = "{9D74B104-40BE-11D2-AA5F-008048E292F1}#1.0#0"; "COLORSELECT.OCX"
  3. Object = "{6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0"; "COMCTL32.OCX"
  4. Begin VB.Form frmShadowLens 
  5.    BorderStyle     =   1  'Fixed Single
  6.    Caption         =   "Shadow lens settings"
  7.    ClientHeight    =   3405
  8.    ClientLeft      =   1905
  9.    ClientTop       =   2010
  10.    ClientWidth     =   4275
  11.    FillColor       =   &H00400000&
  12.    Icon            =   "frmShadowLens.frx":0000
  13.    LinkTopic       =   "Form1"
  14.    MaxButton       =   0   'False
  15.    MinButton       =   0   'False
  16.    ScaleHeight     =   3405
  17.    ScaleWidth      =   4275
  18.    StartUpPosition =   2  'CenterScreen
  19.    Begin VB.OptionButton Option1 
  20.       Caption         =   "Brighten"
  21.       Height          =   495
  22.       Index           =   1
  23.       Left            =   195
  24.       TabIndex        =   2
  25.       Top             =   735
  26.       Width           =   1575
  27.    End
  28.    Begin VB.OptionButton Option1 
  29.       Caption         =   "Transparency"
  30.       Height          =   495
  31.       Index           =   0
  32.       Left            =   195
  33.       TabIndex        =   1
  34.       Top             =   390
  35.       Width           =   1575
  36.    End
  37.    Begin VB.CommandButton btnStartColor 
  38.       Caption         =   "Start Color"
  39.       Height          =   345
  40.       Left            =   2610
  41.       TabIndex        =   9
  42.       Top             =   1320
  43.       Width           =   1065
  44.    End
  45.    Begin VB.CommandButton btnEndColor 
  46.       Caption         =   "End Color"
  47.       Height          =   345
  48.       Left            =   2610
  49.       TabIndex        =   10
  50.       Top             =   1755
  51.       Width           =   1065
  52.    End
  53.    Begin VB.OptionButton Option1 
  54.       Caption         =   "Nothing"
  55.       Height          =   495
  56.       Index           =   8
  57.       Left            =   195
  58.       TabIndex        =   0
  59.       Top             =   45
  60.       Value           =   -1  'True
  61.       Width           =   1575
  62.    End
  63.    Begin VB.CommandButton btnOK 
  64.       Caption         =   "OK"
  65.       Height          =   360
  66.       Left            =   3405
  67.       TabIndex        =   11
  68.       Top             =   2955
  69.       Width           =   735
  70.    End
  71.    Begin ColorSelectLib.ColorSelect ctrlEndColor 
  72.       Height          =   255
  73.       Left            =   3510
  74.       TabIndex        =   13
  75.       Top             =   765
  76.       Width           =   300
  77.       _Version        =   65536
  78.       _ExtentX        =   529
  79.       _ExtentY        =   450
  80.       _StockProps     =   0
  81.    End
  82.    Begin VB.OptionButton Option1 
  83.       Caption         =   "Heatmap Palette"
  84.       Height          =   495
  85.       Index           =   7
  86.       Left            =   195
  87.       TabIndex        =   8
  88.       Top             =   2910
  89.       Width           =   1575
  90.    End
  91.    Begin VB.OptionButton Option1 
  92.       Caption         =   "TintedGrayscale"
  93.       Height          =   495
  94.       Index           =   6
  95.       Left            =   195
  96.       TabIndex        =   7
  97.       Top             =   2550
  98.       Width           =   1575
  99.    End
  100.    Begin VB.OptionButton Option1 
  101.       Caption         =   "Invert"
  102.       Height          =   495
  103.       Index           =   5
  104.       Left            =   195
  105.       TabIndex        =   6
  106.       Top             =   2190
  107.       Width           =   1575
  108.    End
  109.    Begin VB.OptionButton Option1
  110.       Caption         =   "Direct Palette"
  111.       Height          =   495
  112.       Index           =   4
  113.       Left            =   195
  114.       TabIndex        =   5
  115.       Top             =   1830
  116.       Width           =   1575
  117.    End
  118.    Begin VB.OptionButton Option1
  119.       Caption         =   "Limit Color"
  120.       Height          =   495
  121.       Index           =   3
  122.       Left            =   195
  123.       TabIndex        =   4
  124.       Top             =   1455
  125.       Width           =   1575
  126.    End
  127.    Begin VB.OptionButton Option1
  128.       Caption         =   "Add Color"
  129.       Height          =   495
  130.       Index           =   2
  131.       Left            =   195
  132.       TabIndex        =   3
  133.       Top             =   1095
  134.       Width           =   1575
  135.    End
  136.    Begin ColorSelectLib.ColorSelect ctrlStartColor
  137.       Height          =   240
  138.       Left            =   3555
  139.       TabIndex        =   12
  140.       Top             =   585
  141.       Width           =   405
  142.       _Version        =   65536
  143.       _ExtentX        =   714
  144.       _ExtentY        =   423
  145.       _StockProps     =   0
  146.    End
  147.       Begin ComctlLib.Slider sldPercentage
  148.       Height          =   210
  149.       Left            =   2070
  150.       TabIndex        =   9
  151.       Top             =   645
  152.       Width           =   2145
  153.       _ExtentX        =   3784
  154.       _ExtentY        =   370
  155.       _Version        =   327682
  156.       LargeChange     =   10
  157.       Min             =   -100
  158.       Max             =   100
  159.       TickStyle       =   3
  160.    End
  161.    Begin VB.Label lblPercentage
  162.       Caption         =   "Effect percentage:"
  163.       Height          =   285
  164.       Left            =   2085
  165.       TabIndex        =   14
  166.       Top             =   210
  167.       Width           =   2250
  168.    End
  169. End
  170. Attribute VB_Name = "frmShadowLens"
  171. Attribute VB_GlobalNameSpace = False
  172. Attribute VB_Creatable = False
  173. Attribute VB_PredeclaredId = True
  174. Attribute VB_Exposed = False
  175.  
  176. Private Sub btnOK_Click()
  177.     Unload Me
  178. End Sub
  179.  
  180. Private Sub ctrlStartColor_SelectionEndOK()
  181.     frmDrawVB.POLARDraw1.SetSelShadowLensColor ctrlStartColor.SelectedColor
  182. End Sub
  183.  
  184. Private Sub ctrlEndColor_SelectionEndOK()
  185.     
  186.     frmDrawVB.POLARDraw1.SetSelShadowLensBackColor ctrlEndColor.SelectedColor
  187. End Sub
  188.  
  189. Private Sub btnStartColor_Click()
  190.     'Displays Polar ColorSelect dialogbox showing colors
  191.     ColorSelectPosition (ctrlStartColor) 'Function ColorSelectPosition defined in Module1
  192.     ctrlStartColor.SelectColor
  193. End Sub
  194.  
  195. Private Sub btnEndColor_Click()
  196.     'Displays Polar ColorSelect dialogbox for color selection
  197.     ColorSelectPosition (ctrlEndColor) 'Function ColorSelectPosition defined in Module1
  198.     ctrlEndColor.SelectColor
  199. End Sub
  200.  
  201. Private Sub Form_Load()
  202.     Option1(8).Value = True
  203.     lblPercentage.Caption = "Effect percentage: " + CStr(sldPercentage.Value) + "%"
  204.  
  205. End Sub
  206.  
  207. Private Sub Option1_Click(Index As Integer)
  208.     
  209.     frmDrawVB.POLARDraw1.SetSelHasShadow True
  210.     frmDrawVB.POLARDraw1.SetSelHasShadowLens True
  211.     
  212.     Select Case Index
  213.         Case 0
  214.             frmDrawVB.POLARDraw1.SetSelShadowLensType polTransparency
  215.         Case 1
  216.             frmDrawVB.POLARDraw1.SetSelShadowLensType polBrighten
  217.         Case 2
  218.             frmDrawVB.POLARDraw1.SetSelShadowLensType polColorAdd
  219.         Case 3
  220.             frmDrawVB.POLARDraw1.SetSelShadowLensType polColorLimit
  221.         Case 4
  222.             frmDrawVB.POLARDraw1.SetSelShadowLensType polCustomPalette
  223.         Case 5
  224.             frmDrawVB.POLARDraw1.SetSelShadowLensType polInvert
  225.         Case 6
  226.             frmDrawVB.POLARDraw1.SetSelShadowLensType polTintedGrayscale
  227.         Case 7
  228.             frmDrawVB.POLARDraw1.SetSelShadowLensType polHeatmapPalette
  229.         Case 8
  230.             frmDrawVB.POLARDraw1.SetSelHasShadowLens False
  231.     End Select
  232. End Sub
  233.  
  234.  
  235.  
  236. Private Sub sldPercentage_Scroll()
  237.     frmDrawVB.POLARDraw1.SetSelShadowLensPercent sldPercentage.Value
  238.     lblPercentage.Caption = "Effect percentage: " + CStr(sldPercentage.Value) + "%"
  239. End Sub
  240.